package com.sc.nft.admin.request;

import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.hibernate.validator.constraints.Range;

import javax.validation.constraints.DecimalMax;
import javax.validation.constraints.DecimalMin;
import javax.validation.constraints.NotNull;
import java.math.BigDecimal;

@Data
public class EditSecondEquityPropsRequest {

    @ApiModelProperty(value = "id")
    private Long id;


    @ApiModelProperty(value = "最小价")
    @NotNull(message = "最小价不能为空")
    @DecimalMax(value = "99999.99", message = "最小价最大值不能大于99999.99")
    @DecimalMin(value = "1", message = "最小价最小值不能小于1")
    private BigDecimal minPrice;

    @ApiModelProperty(value = "最高价")
    @NotNull(message = "最高价不能为空")
    @DecimalMax(value = "99999.99", message = "最高价最大值不能超过99999.99")
    @DecimalMin(value = "1", message = "最高价最小值不能小于1")
    private BigDecimal maxPrice;

    @ApiModelProperty(value = "手续费比例 列: 50% = 50")
    @NotNull(message = "手续费比例不能为空")
    @DecimalMax(value = "99.99", message = "手续费比例最大值不能超过99.99%")
    @DecimalMin(value = "0.01", message = "手续费比例最小值不能超过0.01%")
    private BigDecimal charge;

    @ApiModelProperty(value = "最低手续费(具体金额)")
    @NotNull(message = "最低手续费不能为空")
    @DecimalMax(value = "99999.99", message = "最低手续费最大值不能大于99999.99")
    @DecimalMin(value = "0.0001", message = "最低手续费最小值不能小于0.0001")
    private BigDecimal minCharge;


    @ApiModelProperty(value = "权重")
    @NotNull(message = "权重不能为空")
    @Range(min = 0, max = 99999999, message = "权重范围为0-99999999")
    private Integer sort;

    @ApiModelProperty("模板Id")
    private Long panelId;

    @ApiModelProperty("是否开启求购")
    @NotNull(message = "是否开启求购不能为空")
    private Boolean enableWantBuy;

    @ApiModelProperty("最低求购价")
    private BigDecimal minWantBuyPrice;

    @ApiModelProperty("最高求购价")
    private BigDecimal maxWantBuyPrice;

    @ApiModelProperty("单次最高求购数量")
    private Integer wantBuyQuantity;

    @ApiModelProperty("求购持有条件")
    private Boolean enableWantBuyHoldCondition;

    @ApiModelProperty("求购消耗道具")
    private Boolean enableWantBuyConsumeProp;

    @ApiModelProperty("求购持有藏品id")
    private Long wantBuyHoldCollectionId;

    @ApiModelProperty("求购消耗道具id")
    private Long wantBuyConsumePropId;

    @ApiModelProperty("求购消耗道具数量")
    private Integer wantBuyConsumePropQuantity;

}
